<?php
	include("$GLOBALS[dir_root]/conf.php");
	include_once("$GLOBALS[dir_class]/CCore.php");

	abstract class ALogger
	{
		public $name;

		private function _debug($s, $lev=0)
		{
			$class = get_class($this);
			$extends = class_parents($class);
			$inst = isset($extends["ALogger"]) ? $this->name : "";
			CCore::debug("[$class \"$inst\"]: $s", $lev);
		}

		public function debug($s)
		{
			$this->_debug($s, 0);
		}

		public function warning($s)
		{
			$this->_debug($s, 1);
		}

		public function error($s)
		{
			$this->_debug($s, 2);
		}

		public function log($s)
		{
			//CCore::log("[$class]: $s");
		}
	}
?>